import React from 'react'
import { useNavigate } from 'react-router-dom'
import { NavBar } from 'antd-mobile'
function MyNavbar(props) {
    const navigate = useNavigate()
    const { title, url = -1 } = props
    return (
        <div>
            <NavBar onBack={() => navigate(url)}>{title}</NavBar>
        </div>
    )
}

export default MyNavbar
